/*
               File: C2
        Description: Conversion for table MMPRS10
             Author: GeneXus Java Generator version 8_0_9-040
       Generated on: 18 de Junio de 2010 12:37:35.6
       Program type: Callable routine
          Main DBMS: sqlserver
*/
import java.sql.*;
import com.genexus.db.*;
import com.genexus.*;
import com.genexus.distributed.*;

public final class c2 extends GXProcedure
{
   public c2( int remoteHandle )
   {
      super( remoteHandle , new ModelContext( c2.class ), "" );
   }

   public c2( int remoteHandle ,
              ModelContext context )
   {
      super( remoteHandle , context, "" );
   }

   public void execute( )
   {
      execute_int();
   }

   private void execute_int( )
   {
      initialize();
      /* GeneXus formulas */
      /* Output device settings */
      /* Using cursor C22 */
      pr_default.execute(0);
      while ( (pr_default.getStatus(0) != 101) )
      {
         A256PrsEma = C22_A256PrsEma[0] ;
         A255PrsEma = C22_A255PrsEma[0] ;
         A254PrsEma = C22_A254PrsEma[0] ;
         A247DISTCO = C22_A247DISTCO[0] ;
         A246PROVCO = C22_A246PROVCO[0] ;
         A245DPTOCO = C22_A245DPTOCO[0] ;
         A244PAICOD = C22_A244PAICOD[0] ;
         A249PrsRef = C22_A249PrsRef[0] ;
         A248PrsDir = C22_A248PrsDir[0] ;
         A243DISTCO = C22_A243DISTCO[0] ;
         A242PROVCO = C22_A242PROVCO[0] ;
         A241DPTOCO = C22_A241DPTOCO[0] ;
         A240PaiCod = C22_A240PaiCod[0] ;
         A239PrsRef = C22_A239PrsRef[0] ;
         A238PrsDir = C22_A238PrsDir[0] ;
         A50PrsTipE = C22_A50PrsTipE[0] ;
         A49PrsNac = C22_A49PrsNac[0] ;
         A48PrsFchA = C22_A48PrsFchA[0] ;
         A45PrsPagW = C22_A45PrsPagW[0] ;
         A46PrsNroT = C22_A46PrsNroT[0] ;
         A44PrsRazC = C22_A44PrsRazC[0] ;
         A43PrsRazS = C22_A43PrsRazS[0] ;
         A42CiiuCod = C22_A42CiiuCod[0] ;
         A83PrsUUM = C22_A83PrsUUM[0] ;
         A82PrsHUM = C22_A82PrsHUM[0] ;
         A81PrsFUM = C22_A81PrsFUM[0] ;
         A80PrsUCR = C22_A80PrsUCR[0] ;
         A79PrsHCR = C22_A79PrsHCR[0] ;
         A78PrsFCR = C22_A78PrsFCR[0] ;
         A77PrsEst = C22_A77PrsEst[0] ;
         A76PrsFlgD = C22_A76PrsFlgD[0] ;
         A70PrsFlgT = C22_A70PrsFlgT[0] ;
         A67SitLabC = C22_A67SitLabC[0] ;
         A66EduNivC = C22_A66EduNivC[0] ;
         A65PrsNroD = C22_A65PrsNroD[0] ;
         A64EstCivC = C22_A64EstCivC[0] ;
         A63PrsSex = C22_A63PrsSex[0] ;
         A61PrsFecN = C22_A61PrsFecN[0] ;
         A60PrsApeM = C22_A60PrsApeM[0] ;
         A59PrsApeP = C22_A59PrsApeP[0] ;
         A58PrsSegN = C22_A58PrsSegN[0] ;
         A57PrsPriN = C22_A57PrsPriN[0] ;
         A56PrsNroR = C22_A56PrsNroR[0] ;
         A55PrsNroD = C22_A55PrsNroD[0] ;
         A53TIPDOCC = C22_A53TIPDOCC[0] ;
         A52TipPrsC = C22_A52TipPrsC[0] ;
         A35PrsCod = C22_A35PrsCod[0] ;
         /*
            INSERT RECORD ON TABLE GXA0002

         */
         AV2PrsCod = A35PrsCod ;
         if ( C22_n52TipPrsC[0] )
         {
            AV3TipPrsC = 0 ;
         }
         else
         {
            AV3TipPrsC = A52TipPrsC ;
         }
         if ( C22_n53TIPDOCC[0] )
         {
            AV4TIPDOCC = 0 ;
         }
         else
         {
            AV4TIPDOCC = A53TIPDOCC ;
         }
         if ( C22_n55PrsNroD[0] )
         {
            AV5PrsNroD = "" ;
         }
         else
         {
            AV5PrsNroD = A55PrsNroD ;
         }
         if ( C22_n56PrsNroR[0] )
         {
            AV6PrsNroR = 0 ;
         }
         else
         {
            AV6PrsNroR = A56PrsNroR ;
         }
         if ( C22_n57PrsPriN[0] )
         {
            AV7PrsPriN = "" ;
         }
         else
         {
            AV7PrsPriN = A57PrsPriN ;
         }
         if ( C22_n58PrsSegN[0] )
         {
            AV8PrsSegN = "" ;
         }
         else
         {
            AV8PrsSegN = A58PrsSegN ;
         }
         if ( C22_n59PrsApeP[0] )
         {
            AV9PrsApeP = "" ;
         }
         else
         {
            AV9PrsApeP = A59PrsApeP ;
         }
         if ( C22_n60PrsApeM[0] )
         {
            AV10PrsApe = "" ;
         }
         else
         {
            AV10PrsApe = A60PrsApeM ;
         }
         if ( C22_n61PrsFecN[0] )
         {
            AV11PrsFec = GXutil.nullDate() ;
         }
         else
         {
            AV11PrsFec = A61PrsFecN ;
         }
         if ( C22_n63PrsSex[0] )
         {
            AV12PrsSex = "" ;
         }
         else
         {
            AV12PrsSex = A63PrsSex ;
         }
         if ( C22_n64EstCivC[0] )
         {
            AV13EstCiv = 0 ;
         }
         else
         {
            AV13EstCiv = A64EstCivC ;
         }
         if ( C22_n65PrsNroD[0] )
         {
            AV14PrsNro = 0 ;
         }
         else
         {
            AV14PrsNro = A65PrsNroD ;
         }
         if ( C22_n66EduNivC[0] )
         {
            AV15EduNiv = 0 ;
         }
         else
         {
            AV15EduNiv = A66EduNivC ;
         }
         if ( C22_n67SitLabC[0] )
         {
            AV16SitLab = 0 ;
         }
         else
         {
            AV16SitLab = A67SitLabC ;
         }
         if ( C22_n70PrsFlgT[0] )
         {
            AV17PrsFlg = "" ;
         }
         else
         {
            AV17PrsFlg = A70PrsFlgT ;
         }
         if ( C22_n76PrsFlgD[0] )
         {
            AV18PrsFlg = "" ;
         }
         else
         {
            AV18PrsFlg = A76PrsFlgD ;
         }
         if ( C22_n77PrsEst[0] )
         {
            AV19PrsEst = "" ;
         }
         else
         {
            AV19PrsEst = A77PrsEst ;
         }
         if ( C22_n78PrsFCR[0] )
         {
            AV20PrsFCR = GXutil.nullDate() ;
         }
         else
         {
            AV20PrsFCR = A78PrsFCR ;
         }
         if ( C22_n79PrsHCR[0] )
         {
            AV21PrsHCR = "" ;
         }
         else
         {
            AV21PrsHCR = A79PrsHCR ;
         }
         if ( C22_n80PrsUCR[0] )
         {
            AV22PrsUCR = "" ;
         }
         else
         {
            AV22PrsUCR = A80PrsUCR ;
         }
         if ( C22_n81PrsFUM[0] )
         {
            AV23PrsFUM = GXutil.nullDate() ;
         }
         else
         {
            AV23PrsFUM = A81PrsFUM ;
         }
         if ( C22_n82PrsHUM[0] )
         {
            AV24PrsHUM = "" ;
         }
         else
         {
            AV24PrsHUM = A82PrsHUM ;
         }
         if ( C22_n83PrsUUM[0] )
         {
            AV25PrsUUM = "" ;
         }
         else
         {
            AV25PrsUUM = A83PrsUUM ;
         }
         if ( C22_n42CiiuCod[0] )
         {
            AV26CiiuCo = 0 ;
         }
         else
         {
            AV26CiiuCo = A42CiiuCod ;
         }
         if ( C22_n43PrsRazS[0] )
         {
            AV27PrsRaz = "" ;
         }
         else
         {
            AV27PrsRaz = A43PrsRazS ;
         }
         if ( C22_n44PrsRazC[0] )
         {
            AV28PrsRaz = "" ;
         }
         else
         {
            AV28PrsRaz = A44PrsRazC ;
         }
         if ( C22_n46PrsNroT[0] )
         {
            AV29PrsNro = 0 ;
         }
         else
         {
            AV29PrsNro = A46PrsNroT ;
         }
         if ( C22_n45PrsPagW[0] )
         {
            AV30PrsPag = "" ;
         }
         else
         {
            AV30PrsPag = A45PrsPagW ;
         }
         if ( C22_n48PrsFchA[0] )
         {
            AV31PrsFch = GXutil.nullDate() ;
         }
         else
         {
            AV31PrsFch = A48PrsFchA ;
         }
         if ( C22_n49PrsNac[0] )
         {
            AV32PrsNac = "" ;
         }
         else
         {
            AV32PrsNac = A49PrsNac ;
         }
         if ( C22_n50PrsTipE[0] )
         {
            AV33PrsTip = "" ;
         }
         else
         {
            AV33PrsTip = A50PrsTipE ;
         }
         if ( C22_n238PrsDir[0] )
         {
            AV34PrsDir = "" ;
         }
         else
         {
            AV34PrsDir = A238PrsDir ;
         }
         if ( C22_n239PrsRef[0] )
         {
            AV35PrsRef = "" ;
         }
         else
         {
            AV35PrsRef = A239PrsRef ;
         }
         if ( C22_n240PaiCod[0] )
         {
            AV36PaiCod = "" ;
         }
         else
         {
            AV36PaiCod = A240PaiCod ;
         }
         if ( C22_n241DPTOCO[0] )
         {
            AV37DPTOCO = "" ;
         }
         else
         {
            AV37DPTOCO = A241DPTOCO ;
         }
         if ( C22_n242PROVCO[0] )
         {
            AV38PROVCO = "" ;
         }
         else
         {
            AV38PROVCO = A242PROVCO ;
         }
         if ( C22_n243DISTCO[0] )
         {
            AV39DISTCO = "" ;
         }
         else
         {
            AV39DISTCO = A243DISTCO ;
         }
         if ( C22_n248PrsDir[0] )
         {
            AV40PrsDir = "" ;
         }
         else
         {
            AV40PrsDir = A248PrsDir ;
         }
         if ( C22_n249PrsRef[0] )
         {
            AV41PrsRef = "" ;
         }
         else
         {
            AV41PrsRef = A249PrsRef ;
         }
         if ( C22_n244PAICOD[0] )
         {
            AV42PAICOD = "" ;
         }
         else
         {
            AV42PAICOD = A244PAICOD ;
         }
         if ( C22_n245DPTOCO[0] )
         {
            AV43DPTOCO = "" ;
         }
         else
         {
            AV43DPTOCO = A245DPTOCO ;
         }
         if ( C22_n246PROVCO[0] )
         {
            AV44PROVCO = "" ;
         }
         else
         {
            AV44PROVCO = A246PROVCO ;
         }
         if ( C22_n247DISTCO[0] )
         {
            AV45DISTCO = "" ;
         }
         else
         {
            AV45DISTCO = A247DISTCO ;
         }
         if ( C22_n254PrsEma[0] )
         {
            AV46PrsEma = "" ;
         }
         else
         {
            AV46PrsEma = A254PrsEma ;
         }
         if ( C22_n255PrsEma[0] )
         {
            AV47PrsEma = "" ;
         }
         else
         {
            AV47PrsEma = A255PrsEma ;
         }
         if ( C22_n256PrsEma[0] )
         {
            AV48PrsEma = "" ;
         }
         else
         {
            AV48PrsEma = A256PrsEma ;
         }
         /* Using cursor C23 */
         pr_default.execute(1, new Object[] {AV2PrsCod, new Byte(AV3TipPrsC), new Short(AV4TIPDOCC), AV5PrsNroD, new Long(AV6PrsNroR), AV7PrsPriN, AV8PrsSegN, AV9PrsApeP, AV10PrsApe, AV11PrsFec, AV12PrsSex, new Byte(AV13EstCiv), new Byte(AV14PrsNro), new Short(AV15EduNiv), new Byte(AV16SitLab), AV17PrsFlg, AV18PrsFlg, AV19PrsEst, AV20PrsFCR, AV21PrsHCR, AV22PrsUCR, AV23PrsFUM, AV24PrsHUM, AV25PrsUUM, new Integer(AV26CiiuCo), AV27PrsRaz, AV28PrsRaz, new Integer(AV29PrsNro), AV30PrsPag, AV31PrsFch, AV32PrsNac, AV33PrsTip, AV34PrsDir, AV35PrsRef, AV36PaiCod, AV37DPTOCO, AV38PROVCO, AV39DISTCO, AV40PrsDir, AV41PrsRef, AV42PAICOD, AV43DPTOCO, AV44PROVCO, AV45DISTCO, AV46PrsEma, AV47PrsEma, AV48PrsEma});
         if ( (pr_default.getStatus(1) == 1) )
         {
            Gx_err = (short)(1) ;
            Gx_emsg = localUtil.getMessages().getMessage("noupdate") ;
         }
         else
         {
            Gx_err = 0 ;
            Gx_emsg = "" ;
         }
         /* End Insert */
         pr_default.readNext(0);
      }
      pr_default.close(0);
      cleanup();
   }

   protected void cleanup( )
   {
      exitApplication();
   }

   /* Aggregate/select formulas */
   public void initialize( )
   {
      C22_A256PrsEma = new String[] {""} ;
      C22_A255PrsEma = new String[] {""} ;
      C22_A254PrsEma = new String[] {""} ;
      C22_A247DISTCO = new String[] {""} ;
      C22_A246PROVCO = new String[] {""} ;
      C22_A245DPTOCO = new String[] {""} ;
      C22_A244PAICOD = new String[] {""} ;
      C22_A249PrsRef = new String[] {""} ;
      C22_A248PrsDir = new String[] {""} ;
      C22_A243DISTCO = new String[] {""} ;
      C22_A242PROVCO = new String[] {""} ;
      C22_A241DPTOCO = new String[] {""} ;
      C22_A240PaiCod = new String[] {""} ;
      C22_A239PrsRef = new String[] {""} ;
      C22_A238PrsDir = new String[] {""} ;
      C22_A50PrsTipE = new String[] {""} ;
      C22_A49PrsNac = new String[] {""} ;
      C22_A48PrsFchA = new java.util.Date[] {GXutil.nullDate()} ;
      C22_A45PrsPagW = new String[] {""} ;
      C22_A46PrsNroT = new int[1] ;
      C22_A44PrsRazC = new String[] {""} ;
      C22_A43PrsRazS = new String[] {""} ;
      C22_A42CiiuCod = new int[1] ;
      C22_A83PrsUUM = new String[] {""} ;
      C22_A82PrsHUM = new String[] {""} ;
      C22_A81PrsFUM = new java.util.Date[] {GXutil.nullDate()} ;
      C22_A80PrsUCR = new String[] {""} ;
      C22_A79PrsHCR = new String[] {""} ;
      C22_A78PrsFCR = new java.util.Date[] {GXutil.nullDate()} ;
      C22_A77PrsEst = new String[] {""} ;
      C22_A76PrsFlgD = new String[] {""} ;
      C22_A70PrsFlgT = new String[] {""} ;
      C22_A67SitLabC = new byte[1] ;
      C22_A66EduNivC = new short[1] ;
      C22_A65PrsNroD = new byte[1] ;
      C22_A64EstCivC = new byte[1] ;
      C22_A63PrsSex = new String[] {""} ;
      C22_A61PrsFecN = new java.util.Date[] {GXutil.nullDate()} ;
      C22_A60PrsApeM = new String[] {""} ;
      C22_A59PrsApeP = new String[] {""} ;
      C22_A58PrsSegN = new String[] {""} ;
      C22_A57PrsPriN = new String[] {""} ;
      C22_A56PrsNroR = new long[1] ;
      C22_A55PrsNroD = new String[] {""} ;
      C22_A53TIPDOCC = new short[1] ;
      C22_A52TipPrsC = new byte[1] ;
      C22_A35PrsCod = new String[] {""} ;
      A256PrsEma = "" ;
      A255PrsEma = "" ;
      A254PrsEma = "" ;
      A247DISTCO = "" ;
      A246PROVCO = "" ;
      A245DPTOCO = "" ;
      A244PAICOD = "" ;
      A249PrsRef = "" ;
      A248PrsDir = "" ;
      A243DISTCO = "" ;
      A242PROVCO = "" ;
      A241DPTOCO = "" ;
      A240PaiCod = "" ;
      A239PrsRef = "" ;
      A238PrsDir = "" ;
      A50PrsTipE = "" ;
      A49PrsNac = "" ;
      A48PrsFchA = GXutil.nullDate() ;
      A45PrsPagW = "" ;
      A46PrsNroT = 0 ;
      A44PrsRazC = "" ;
      A43PrsRazS = "" ;
      A42CiiuCod = 0 ;
      A83PrsUUM = "" ;
      A82PrsHUM = "" ;
      A81PrsFUM = GXutil.nullDate() ;
      A80PrsUCR = "" ;
      A79PrsHCR = "" ;
      A78PrsFCR = GXutil.nullDate() ;
      A77PrsEst = "" ;
      A76PrsFlgD = "" ;
      A70PrsFlgT = "" ;
      A67SitLabC = 0 ;
      A66EduNivC = 0 ;
      A65PrsNroD = 0 ;
      A64EstCivC = 0 ;
      A63PrsSex = "" ;
      A61PrsFecN = GXutil.nullDate() ;
      A60PrsApeM = "" ;
      A59PrsApeP = "" ;
      A58PrsSegN = "" ;
      A57PrsPriN = "" ;
      A56PrsNroR = 0 ;
      A55PrsNroD = "" ;
      A53TIPDOCC = 0 ;
      A52TipPrsC = 0 ;
      A35PrsCod = "" ;
      GIGXA0002 = 0 ;
      AV2PrsCod = "" ;
      C22_n52TipPrsC = new boolean[] {false} ;
      AV3TipPrsC = 0 ;
      C22_n53TIPDOCC = new boolean[] {false} ;
      AV4TIPDOCC = 0 ;
      C22_n55PrsNroD = new boolean[] {false} ;
      AV5PrsNroD = "" ;
      C22_n56PrsNroR = new boolean[] {false} ;
      AV6PrsNroR = 0 ;
      C22_n57PrsPriN = new boolean[] {false} ;
      AV7PrsPriN = "" ;
      C22_n58PrsSegN = new boolean[] {false} ;
      AV8PrsSegN = "" ;
      C22_n59PrsApeP = new boolean[] {false} ;
      AV9PrsApeP = "" ;
      C22_n60PrsApeM = new boolean[] {false} ;
      AV10PrsApe = "" ;
      C22_n61PrsFecN = new boolean[] {false} ;
      AV11PrsFec = GXutil.nullDate() ;
      C22_n63PrsSex = new boolean[] {false} ;
      AV12PrsSex = "" ;
      C22_n64EstCivC = new boolean[] {false} ;
      AV13EstCiv = 0 ;
      C22_n65PrsNroD = new boolean[] {false} ;
      AV14PrsNro = 0 ;
      C22_n66EduNivC = new boolean[] {false} ;
      AV15EduNiv = 0 ;
      C22_n67SitLabC = new boolean[] {false} ;
      AV16SitLab = 0 ;
      C22_n70PrsFlgT = new boolean[] {false} ;
      AV17PrsFlg = "" ;
      C22_n76PrsFlgD = new boolean[] {false} ;
      AV18PrsFlg = "" ;
      C22_n77PrsEst = new boolean[] {false} ;
      AV19PrsEst = "" ;
      C22_n78PrsFCR = new boolean[] {false} ;
      AV20PrsFCR = GXutil.nullDate() ;
      C22_n79PrsHCR = new boolean[] {false} ;
      AV21PrsHCR = "" ;
      C22_n80PrsUCR = new boolean[] {false} ;
      AV22PrsUCR = "" ;
      C22_n81PrsFUM = new boolean[] {false} ;
      AV23PrsFUM = GXutil.nullDate() ;
      C22_n82PrsHUM = new boolean[] {false} ;
      AV24PrsHUM = "" ;
      C22_n83PrsUUM = new boolean[] {false} ;
      AV25PrsUUM = "" ;
      C22_n42CiiuCod = new boolean[] {false} ;
      AV26CiiuCo = 0 ;
      C22_n43PrsRazS = new boolean[] {false} ;
      AV27PrsRaz = "" ;
      C22_n44PrsRazC = new boolean[] {false} ;
      AV28PrsRaz = "" ;
      C22_n46PrsNroT = new boolean[] {false} ;
      AV29PrsNro = 0 ;
      C22_n45PrsPagW = new boolean[] {false} ;
      AV30PrsPag = "" ;
      C22_n48PrsFchA = new boolean[] {false} ;
      AV31PrsFch = GXutil.nullDate() ;
      C22_n49PrsNac = new boolean[] {false} ;
      AV32PrsNac = "" ;
      C22_n50PrsTipE = new boolean[] {false} ;
      AV33PrsTip = "" ;
      C22_n238PrsDir = new boolean[] {false} ;
      AV34PrsDir = "" ;
      C22_n239PrsRef = new boolean[] {false} ;
      AV35PrsRef = "" ;
      C22_n240PaiCod = new boolean[] {false} ;
      AV36PaiCod = "" ;
      C22_n241DPTOCO = new boolean[] {false} ;
      AV37DPTOCO = "" ;
      C22_n242PROVCO = new boolean[] {false} ;
      AV38PROVCO = "" ;
      C22_n243DISTCO = new boolean[] {false} ;
      AV39DISTCO = "" ;
      C22_n248PrsDir = new boolean[] {false} ;
      AV40PrsDir = "" ;
      C22_n249PrsRef = new boolean[] {false} ;
      AV41PrsRef = "" ;
      C22_n244PAICOD = new boolean[] {false} ;
      AV42PAICOD = "" ;
      C22_n245DPTOCO = new boolean[] {false} ;
      AV43DPTOCO = "" ;
      C22_n246PROVCO = new boolean[] {false} ;
      AV44PROVCO = "" ;
      C22_n247DISTCO = new boolean[] {false} ;
      AV45DISTCO = "" ;
      C22_n254PrsEma = new boolean[] {false} ;
      AV46PrsEma = "" ;
      C22_n255PrsEma = new boolean[] {false} ;
      AV47PrsEma = "" ;
      C22_n256PrsEma = new boolean[] {false} ;
      AV48PrsEma = "" ;
      Gx_err = 0 ;
      Gx_emsg = "" ;
      pr_default = new DataStoreProvider(context, remoteHandle, new c2__default(),
         new Object[] {
             new Object[] {
            C22_A256PrsEma, C22_n256PrsEma, C22_A255PrsEma, C22_n255PrsEma, C22_A254PrsEma, C22_n254PrsEma, C22_A247DISTCO, C22_n247DISTCO, C22_A246PROVCO, C22_n246PROVCO,
            C22_A245DPTOCO, C22_n245DPTOCO, C22_A244PAICOD, C22_n244PAICOD, C22_A249PrsRef, C22_n249PrsRef, C22_A248PrsDir, C22_n248PrsDir, C22_A243DISTCO, C22_n243DISTCO,
            C22_A242PROVCO, C22_n242PROVCO, C22_A241DPTOCO, C22_n241DPTOCO, C22_A240PaiCod, C22_n240PaiCod, C22_A239PrsRef, C22_n239PrsRef, C22_A238PrsDir, C22_n238PrsDir,
            C22_A50PrsTipE, C22_n50PrsTipE, C22_A49PrsNac, C22_n49PrsNac, C22_A48PrsFchA, C22_n48PrsFchA, C22_A45PrsPagW, C22_n45PrsPagW, C22_A46PrsNroT, C22_n46PrsNroT,
            C22_A44PrsRazC, C22_n44PrsRazC, C22_A43PrsRazS, C22_n43PrsRazS, C22_A42CiiuCod, C22_n42CiiuCod, C22_A83PrsUUM, C22_n83PrsUUM, C22_A82PrsHUM, C22_n82PrsHUM,
            C22_A81PrsFUM, C22_n81PrsFUM, C22_A80PrsUCR, C22_n80PrsUCR, C22_A79PrsHCR, C22_n79PrsHCR, C22_A78PrsFCR, C22_n78PrsFCR, C22_A77PrsEst, C22_n77PrsEst,
            C22_A76PrsFlgD, C22_n76PrsFlgD, C22_A70PrsFlgT, C22_n70PrsFlgT, C22_A67SitLabC, C22_n67SitLabC, C22_A66EduNivC, C22_n66EduNivC, C22_A65PrsNroD, C22_n65PrsNroD,
            C22_A64EstCivC, C22_n64EstCivC, C22_A63PrsSex, C22_n63PrsSex, C22_A61PrsFecN, C22_n61PrsFecN, C22_A60PrsApeM, C22_n60PrsApeM, C22_A59PrsApeP, C22_n59PrsApeP,
            C22_A58PrsSegN, C22_n58PrsSegN, C22_A57PrsPriN, C22_n57PrsPriN, C22_A56PrsNroR, C22_n56PrsNroR, C22_A55PrsNroD, C22_n55PrsNroD, C22_A53TIPDOCC, C22_n53TIPDOCC,
            C22_A52TipPrsC, C22_n52TipPrsC, C22_A35PrsCod
            }
            , new Object[] {
            }
         }
      );
      /* GeneXus formulas. */
      Gx_err = 0 ;
   }

   private byte A67SitLabC ;
   private byte A65PrsNroD ;
   private byte A64EstCivC ;
   private byte A52TipPrsC ;
   private byte AV3TipPrsC ;
   private byte AV13EstCiv ;
   private byte AV14PrsNro ;
   private byte AV16SitLab ;
   private short A66EduNivC ;
   private short A53TIPDOCC ;
   private short AV4TIPDOCC ;
   private short AV15EduNiv ;
   private short Gx_err ;
   private int A46PrsNroT ;
   private int A42CiiuCod ;
   private int GIGXA0002 ;
   private int AV26CiiuCo ;
   private int AV29PrsNro ;
   private long A56PrsNroR ;
   private long AV6PrsNroR ;
   private String A256PrsEma ;
   private String A255PrsEma ;
   private String A254PrsEma ;
   private String A247DISTCO ;
   private String A246PROVCO ;
   private String A245DPTOCO ;
   private String A244PAICOD ;
   private String A249PrsRef ;
   private String A248PrsDir ;
   private String A243DISTCO ;
   private String A242PROVCO ;
   private String A241DPTOCO ;
   private String A240PaiCod ;
   private String A239PrsRef ;
   private String A238PrsDir ;
   private String A50PrsTipE ;
   private String A49PrsNac ;
   private String A45PrsPagW ;
   private String A44PrsRazC ;
   private String A43PrsRazS ;
   private String A83PrsUUM ;
   private String A82PrsHUM ;
   private String A80PrsUCR ;
   private String A79PrsHCR ;
   private String A77PrsEst ;
   private String A76PrsFlgD ;
   private String A70PrsFlgT ;
   private String A63PrsSex ;
   private String A60PrsApeM ;
   private String A59PrsApeP ;
   private String A58PrsSegN ;
   private String A57PrsPriN ;
   private String A55PrsNroD ;
   private String A35PrsCod ;
   private String AV2PrsCod ;
   private String AV5PrsNroD ;
   private String AV7PrsPriN ;
   private String AV8PrsSegN ;
   private String AV9PrsApeP ;
   private String AV10PrsApe ;
   private String AV12PrsSex ;
   private String AV17PrsFlg ;
   private String AV18PrsFlg ;
   private String AV19PrsEst ;
   private String AV21PrsHCR ;
   private String AV22PrsUCR ;
   private String AV24PrsHUM ;
   private String AV25PrsUUM ;
   private String AV27PrsRaz ;
   private String AV28PrsRaz ;
   private String AV30PrsPag ;
   private String AV32PrsNac ;
   private String AV33PrsTip ;
   private String AV34PrsDir ;
   private String AV35PrsRef ;
   private String AV36PaiCod ;
   private String AV37DPTOCO ;
   private String AV38PROVCO ;
   private String AV39DISTCO ;
   private String AV40PrsDir ;
   private String AV41PrsRef ;
   private String AV42PAICOD ;
   private String AV43DPTOCO ;
   private String AV44PROVCO ;
   private String AV45DISTCO ;
   private String AV46PrsEma ;
   private String AV47PrsEma ;
   private String AV48PrsEma ;
   private String Gx_emsg ;
   private java.util.Date A48PrsFchA ;
   private java.util.Date A81PrsFUM ;
   private java.util.Date A78PrsFCR ;
   private java.util.Date A61PrsFecN ;
   private java.util.Date AV11PrsFec ;
   private java.util.Date AV20PrsFCR ;
   private java.util.Date AV23PrsFUM ;
   private java.util.Date AV31PrsFch ;
   private IDataStoreProvider pr_default ;
   private String[] C22_A256PrsEma ;
   private String[] C22_A255PrsEma ;
   private String[] C22_A254PrsEma ;
   private String[] C22_A247DISTCO ;
   private String[] C22_A246PROVCO ;
   private String[] C22_A245DPTOCO ;
   private String[] C22_A244PAICOD ;
   private String[] C22_A249PrsRef ;
   private String[] C22_A248PrsDir ;
   private String[] C22_A243DISTCO ;
   private String[] C22_A242PROVCO ;
   private String[] C22_A241DPTOCO ;
   private String[] C22_A240PaiCod ;
   private String[] C22_A239PrsRef ;
   private String[] C22_A238PrsDir ;
   private String[] C22_A50PrsTipE ;
   private String[] C22_A49PrsNac ;
   private java.util.Date[] C22_A48PrsFchA ;
   private String[] C22_A45PrsPagW ;
   private int[] C22_A46PrsNroT ;
   private String[] C22_A44PrsRazC ;
   private String[] C22_A43PrsRazS ;
   private int[] C22_A42CiiuCod ;
   private String[] C22_A83PrsUUM ;
   private String[] C22_A82PrsHUM ;
   private java.util.Date[] C22_A81PrsFUM ;
   private String[] C22_A80PrsUCR ;
   private String[] C22_A79PrsHCR ;
   private java.util.Date[] C22_A78PrsFCR ;
   private String[] C22_A77PrsEst ;
   private String[] C22_A76PrsFlgD ;
   private String[] C22_A70PrsFlgT ;
   private byte[] C22_A67SitLabC ;
   private short[] C22_A66EduNivC ;
   private byte[] C22_A65PrsNroD ;
   private byte[] C22_A64EstCivC ;
   private String[] C22_A63PrsSex ;
   private java.util.Date[] C22_A61PrsFecN ;
   private String[] C22_A60PrsApeM ;
   private String[] C22_A59PrsApeP ;
   private String[] C22_A58PrsSegN ;
   private String[] C22_A57PrsPriN ;
   private long[] C22_A56PrsNroR ;
   private String[] C22_A55PrsNroD ;
   private short[] C22_A53TIPDOCC ;
   private byte[] C22_A52TipPrsC ;
   private String[] C22_A35PrsCod ;
   private boolean[] C22_n52TipPrsC ;
   private boolean[] C22_n53TIPDOCC ;
   private boolean[] C22_n55PrsNroD ;
   private boolean[] C22_n56PrsNroR ;
   private boolean[] C22_n57PrsPriN ;
   private boolean[] C22_n58PrsSegN ;
   private boolean[] C22_n59PrsApeP ;
   private boolean[] C22_n60PrsApeM ;
   private boolean[] C22_n61PrsFecN ;
   private boolean[] C22_n63PrsSex ;
   private boolean[] C22_n64EstCivC ;
   private boolean[] C22_n65PrsNroD ;
   private boolean[] C22_n66EduNivC ;
   private boolean[] C22_n67SitLabC ;
   private boolean[] C22_n70PrsFlgT ;
   private boolean[] C22_n76PrsFlgD ;
   private boolean[] C22_n77PrsEst ;
   private boolean[] C22_n78PrsFCR ;
   private boolean[] C22_n79PrsHCR ;
   private boolean[] C22_n80PrsUCR ;
   private boolean[] C22_n81PrsFUM ;
   private boolean[] C22_n82PrsHUM ;
   private boolean[] C22_n83PrsUUM ;
   private boolean[] C22_n42CiiuCod ;
   private boolean[] C22_n43PrsRazS ;
   private boolean[] C22_n44PrsRazC ;
   private boolean[] C22_n46PrsNroT ;
   private boolean[] C22_n45PrsPagW ;
   private boolean[] C22_n48PrsFchA ;
   private boolean[] C22_n49PrsNac ;
   private boolean[] C22_n50PrsTipE ;
   private boolean[] C22_n238PrsDir ;
   private boolean[] C22_n239PrsRef ;
   private boolean[] C22_n240PaiCod ;
   private boolean[] C22_n241DPTOCO ;
   private boolean[] C22_n242PROVCO ;
   private boolean[] C22_n243DISTCO ;
   private boolean[] C22_n248PrsDir ;
   private boolean[] C22_n249PrsRef ;
   private boolean[] C22_n244PAICOD ;
   private boolean[] C22_n245DPTOCO ;
   private boolean[] C22_n246PROVCO ;
   private boolean[] C22_n247DISTCO ;
   private boolean[] C22_n254PrsEma ;
   private boolean[] C22_n255PrsEma ;
   private boolean[] C22_n256PrsEma ;
}

final class c2__default extends DataStoreHelperBase implements ILocalDataStoreHelper
{
   public Cursor[] getCursors( )
   {
      return new Cursor[] {
          new ForEachCursor("C22", "SELECT [PrsEmai3], [PrsEmai2], [PrsEmai1], [DISTCOD2], [PROVCOD2], [DPTOCOD2], [PAICOD2], [PrsRefDir2], [PrsDir2], [DISTCOD1], [PROVCOD1], [DPTOCOD1], [PaiCod1], [PrsRefDir1], [PrsDir1], [PrsTipEmp], [PrsNac], [PrsFchAni], [PrsPagWeb], [PrsNroTrb], [PrsRazCom], [PrsRazSoc], [CiiuCod], [PrsUUM], [PrsHUM], [PrsFUM], [PrsUCR], [PrsHCR], [PrsFCR], [PrsEst], [PrsFlgDErr], [PrsFlgTarC], [SitLabCod], [EduNivCod], [PrsNroDep], [EstCivCod], [PrsSex], [PrsFecNac], [PrsApeMat], [PrsApePat], [PrsSegNom], [PrsPriNom], [PrsNroRUC], [PrsNroDoc], [TIPDOCCOD], [TipPrsCod], [PrsCod] FROM [MMPRS10] WITH (NOLOCK) ORDER BY [PrsCod] ",false, GX_NOMASK + GX_MASKLOOPLOCK, false, this,0,false )
         ,new UpdateCursor("C23", "INSERT INTO [GXA0002] ([PrsCod], [TipPrsCod], [TIPDOCCOD], [PrsNroDoc], [PrsNroRUC], [PrsPriNom], [PrsSegNom], [PrsApePat], [PrsApeMat], [PrsFecNac], [PrsSex], [EstCivCod], [PrsNroDep], [EduNivCod], [SitLabCod], [PrsFlgTarC], [PrsFlgDErr], [PrsEst], [PrsFCR], [PrsHCR], [PrsUCR], [PrsFUM], [PrsHUM], [PrsUUM], [CiiuCod], [PrsRazSoc], [PrsRazCom], [PrsNroTrb], [PrsPagWeb], [PrsFchAni], [PrsNac], [PrsTipEmp], [PrsDir1], [PrsRefDir1], [PaiCod1], [DPTOCOD1], [PROVCOD1], [DISTCOD1], [PrsDir2], [PrsRefDir2], [PAICOD2], [DPTOCOD2], [PROVCOD2], [DISTCOD2], [PrsEmai1], [PrsEmai2], [PrsEmai3]) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)", GX_NOMASK + GX_MASKLOOPLOCK)
      };
   }

   public void getResults( int cursor ,
                           IFieldGetter rslt ,
                           Object[] buf ) throws SQLException
   {
      switch ( cursor )
      {
            case 0 :
               ((String[]) buf[0])[0] = rslt.getString(1, 100) ;
               ((boolean[]) buf[1])[0] = rslt.wasNull();
               ((String[]) buf[2])[0] = rslt.getString(2, 100) ;
               ((boolean[]) buf[3])[0] = rslt.wasNull();
               ((String[]) buf[4])[0] = rslt.getString(3, 100) ;
               ((boolean[]) buf[5])[0] = rslt.wasNull();
               ((String[]) buf[6])[0] = rslt.getString(4, 3) ;
               ((boolean[]) buf[7])[0] = rslt.wasNull();
               ((String[]) buf[8])[0] = rslt.getString(5, 3) ;
               ((boolean[]) buf[9])[0] = rslt.wasNull();
               ((String[]) buf[10])[0] = rslt.getString(6, 3) ;
               ((boolean[]) buf[11])[0] = rslt.wasNull();
               ((String[]) buf[12])[0] = rslt.getString(7, 3) ;
               ((boolean[]) buf[13])[0] = rslt.wasNull();
               ((String[]) buf[14])[0] = rslt.getString(8, 200) ;
               ((boolean[]) buf[15])[0] = rslt.wasNull();
               ((String[]) buf[16])[0] = rslt.getString(9, 200) ;
               ((boolean[]) buf[17])[0] = rslt.wasNull();
               ((String[]) buf[18])[0] = rslt.getString(10, 3) ;
               ((boolean[]) buf[19])[0] = rslt.wasNull();
               ((String[]) buf[20])[0] = rslt.getString(11, 3) ;
               ((boolean[]) buf[21])[0] = rslt.wasNull();
               ((String[]) buf[22])[0] = rslt.getString(12, 3) ;
               ((boolean[]) buf[23])[0] = rslt.wasNull();
               ((String[]) buf[24])[0] = rslt.getString(13, 3) ;
               ((boolean[]) buf[25])[0] = rslt.wasNull();
               ((String[]) buf[26])[0] = rslt.getString(14, 200) ;
               ((boolean[]) buf[27])[0] = rslt.wasNull();
               ((String[]) buf[28])[0] = rslt.getString(15, 200) ;
               ((boolean[]) buf[29])[0] = rslt.wasNull();
               ((String[]) buf[30])[0] = rslt.getString(16, 1) ;
               ((boolean[]) buf[31])[0] = rslt.wasNull();
               ((String[]) buf[32])[0] = rslt.getString(17, 1) ;
               ((boolean[]) buf[33])[0] = rslt.wasNull();
               ((java.util.Date[]) buf[34])[0] = rslt.getGXDate(18) ;
               ((boolean[]) buf[35])[0] = rslt.wasNull();
               ((String[]) buf[36])[0] = rslt.getString(19, 50) ;
               ((boolean[]) buf[37])[0] = rslt.wasNull();
               ((int[]) buf[38])[0] = rslt.getInt(20) ;
               ((boolean[]) buf[39])[0] = rslt.wasNull();
               ((String[]) buf[40])[0] = rslt.getString(21, 50) ;
               ((boolean[]) buf[41])[0] = rslt.wasNull();
               ((String[]) buf[42])[0] = rslt.getString(22, 50) ;
               ((boolean[]) buf[43])[0] = rslt.wasNull();
               ((int[]) buf[44])[0] = rslt.getInt(23) ;
               ((boolean[]) buf[45])[0] = rslt.wasNull();
               ((String[]) buf[46])[0] = rslt.getString(24, 10) ;
               ((boolean[]) buf[47])[0] = rslt.wasNull();
               ((String[]) buf[48])[0] = rslt.getString(25, 8) ;
               ((boolean[]) buf[49])[0] = rslt.wasNull();
               ((java.util.Date[]) buf[50])[0] = rslt.getGXDate(26) ;
               ((boolean[]) buf[51])[0] = rslt.wasNull();
               ((String[]) buf[52])[0] = rslt.getString(27, 10) ;
               ((boolean[]) buf[53])[0] = rslt.wasNull();
               ((String[]) buf[54])[0] = rslt.getString(28, 8) ;
               ((boolean[]) buf[55])[0] = rslt.wasNull();
               ((java.util.Date[]) buf[56])[0] = rslt.getGXDate(29) ;
               ((boolean[]) buf[57])[0] = rslt.wasNull();
               ((String[]) buf[58])[0] = rslt.getString(30, 1) ;
               ((boolean[]) buf[59])[0] = rslt.wasNull();
               ((String[]) buf[60])[0] = rslt.getString(31, 1) ;
               ((boolean[]) buf[61])[0] = rslt.wasNull();
               ((String[]) buf[62])[0] = rslt.getString(32, 1) ;
               ((boolean[]) buf[63])[0] = rslt.wasNull();
               ((byte[]) buf[64])[0] = rslt.getByte(33) ;
               ((boolean[]) buf[65])[0] = rslt.wasNull();
               ((short[]) buf[66])[0] = rslt.getShort(34) ;
               ((boolean[]) buf[67])[0] = rslt.wasNull();
               ((byte[]) buf[68])[0] = rslt.getByte(35) ;
               ((boolean[]) buf[69])[0] = rslt.wasNull();
               ((byte[]) buf[70])[0] = rslt.getByte(36) ;
               ((boolean[]) buf[71])[0] = rslt.wasNull();
               ((String[]) buf[72])[0] = rslt.getString(37, 1) ;
               ((boolean[]) buf[73])[0] = rslt.wasNull();
               ((java.util.Date[]) buf[74])[0] = rslt.getGXDate(38) ;
               ((boolean[]) buf[75])[0] = rslt.wasNull();
               ((String[]) buf[76])[0] = rslt.getString(39, 20) ;
               ((boolean[]) buf[77])[0] = rslt.wasNull();
               ((String[]) buf[78])[0] = rslt.getString(40, 20) ;
               ((boolean[]) buf[79])[0] = rslt.wasNull();
               ((String[]) buf[80])[0] = rslt.getString(41, 15) ;
               ((boolean[]) buf[81])[0] = rslt.wasNull();
               ((String[]) buf[82])[0] = rslt.getString(42, 15) ;
               ((boolean[]) buf[83])[0] = rslt.wasNull();
               ((long[]) buf[84])[0] = rslt.getLong(43) ;
               ((boolean[]) buf[85])[0] = rslt.wasNull();
               ((String[]) buf[86])[0] = rslt.getString(44, 15) ;
               ((boolean[]) buf[87])[0] = rslt.wasNull();
               ((short[]) buf[88])[0] = rslt.getShort(45) ;
               ((boolean[]) buf[89])[0] = rslt.wasNull();
               ((byte[]) buf[90])[0] = rslt.getByte(46) ;
               ((boolean[]) buf[91])[0] = rslt.wasNull();
               ((String[]) buf[92])[0] = rslt.getString(47, 10) ;
               break;
      }
   }

   public void setParameters( int cursor ,
                              IFieldSetter stmt ,
                              Object[] parms ) throws SQLException
   {
      switch ( cursor )
      {
            case 1 :
               stmt.setString(1, (String)parms[0], 10);
               stmt.setByte(2, ((Byte) parms[1]).byteValue());
               stmt.setShort(3, ((Short) parms[2]).shortValue());
               stmt.setString(4, (String)parms[3], 15);
               stmt.setLong(5, ((Long) parms[4]).longValue());
               stmt.setString(6, (String)parms[5], 15);
               stmt.setString(7, (String)parms[6], 15);
               stmt.setString(8, (String)parms[7], 20);
               stmt.setString(9, (String)parms[8], 20);
               stmt.setDate(10, (java.util.Date)parms[9]);
               stmt.setString(11, (String)parms[10], 1);
               stmt.setByte(12, ((Byte) parms[11]).byteValue());
               stmt.setByte(13, ((Byte) parms[12]).byteValue());
               stmt.setShort(14, ((Short) parms[13]).shortValue());
               stmt.setByte(15, ((Byte) parms[14]).byteValue());
               stmt.setString(16, (String)parms[15], 1);
               stmt.setString(17, (String)parms[16], 1);
               stmt.setString(18, (String)parms[17], 1);
               stmt.setDate(19, (java.util.Date)parms[18]);
               stmt.setString(20, (String)parms[19], 8);
               stmt.setString(21, (String)parms[20], 10);
               stmt.setDate(22, (java.util.Date)parms[21]);
               stmt.setString(23, (String)parms[22], 8);
               stmt.setString(24, (String)parms[23], 10);
               stmt.setInt(25, ((Integer) parms[24]).intValue());
               stmt.setString(26, (String)parms[25], 50);
               stmt.setString(27, (String)parms[26], 50);
               stmt.setInt(28, ((Integer) parms[27]).intValue());
               stmt.setString(29, (String)parms[28], 50);
               stmt.setDate(30, (java.util.Date)parms[29]);
               stmt.setString(31, (String)parms[30], 1);
               stmt.setString(32, (String)parms[31], 1);
               stmt.setString(33, (String)parms[32], 200);
               stmt.setString(34, (String)parms[33], 200);
               stmt.setString(35, (String)parms[34], 3);
               stmt.setString(36, (String)parms[35], 3);
               stmt.setString(37, (String)parms[36], 3);
               stmt.setString(38, (String)parms[37], 3);
               stmt.setString(39, (String)parms[38], 200);
               stmt.setString(40, (String)parms[39], 200);
               stmt.setString(41, (String)parms[40], 3);
               stmt.setString(42, (String)parms[41], 3);
               stmt.setString(43, (String)parms[42], 3);
               stmt.setString(44, (String)parms[43], 3);
               stmt.setString(45, (String)parms[44], 100);
               stmt.setString(46, (String)parms[45], 100);
               stmt.setString(47, (String)parms[46], 100);
               break;
      }
   }

}

